home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 14155 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.5 KB  |  36 lines

  1. Newsgroups: comp.lang.c++,comp.os.ms-windows.programmer.win32
  2. Path: netcom.com!alan
  3. From: alan@netcom.com (Robert Alan Wright)
  4. Subject: VC++ 4.0 memory allocation slower than in 2.x!!!
  5. Message-ID: <alanDozpsy.Kn6@netcom.com>
  6. Organization: NETCOM On-line Communication Services (408 261-4700 guest)
  7. Date: Thu, 28 Mar 1996 18:24:33 GMT
  8. Sender: alan@netcom14.netcom.com
  9.  
  10. I recently posted a request for help in determining why a program which
  11. was simply recompiled on VC++4.0 suddenly ran 3 times slower than the
  12. same one did under VC++ 2.0.
  13.  
  14. I went through all the usual steps of making sure that I had the right
  15. compiler/link settings and even built my own version of the MFC
  16. libraries to make sure they were fully optimized. 
  17.  
  18. Upon further profiling and other exploration, I found out the problem:
  19. THE VC++ 4.0 MEMORY ALLOCATION ROUTINES ARE WAY SLOWER!!!
  20.  
  21. I don't understand how this can be, but I switched from using the
  22. Microsoft malloc/realloc routines to my own versions, and now I
  23. get about the same performance from the app that I used to.
  24. As best I can tell, the new realloc routine is about 10 TIMES SLOWER
  25. than the old one, and malloc is also slower. At this point, I
  26. have replaced the use of almost all Microsoft MFC classes as well as
  27. C/C++ runtime routines in order to get decent performance. I am quite
  28. disgusted in the apparent low quality of their implementations.
  29.  
  30. Can anyone offer any more rational explanation for this than that
  31. Microsoft has horrible quality control? I'm having a hard time
  32. believing they could do screw up this badly.
  33.  
  34. Alan
  35.  
  36.